package edu.sdufe.map.TreeMap;

import java.util.Comparator;
import java.util.TreeMap;

/**
 * @author wang'ji'cheng
 * @date 2025/7/26
 */
public class Demo1 {
    public static void main(String[] args) {

        TreeMap<Integer, String> tm = new TreeMap<>((o1, o2)->o2-o1);

        tm.put(5, "前期");
        tm.put(1, "张三");
        tm.put(2, "李四");
        tm.put(3, "王五");
        tm.put(4, "赵六");

        System.out.println(tm);
    }
}
